package org.langqiao.algorithm;
//中国福利彩票35选7dd
public class CaiPiao {
	
	public static void main(String[] args) {
		System.out.println("中国福利彩票35选7");
		for(int i = 0;i < 10;i++) {
			//调用自定义的getter()方法
			getter();
			System.out.println();
		}
	}
	
	public static void getter() {
		int i,j,m;
		int[] a = new int[7];
		for(i = 0;i < 7;i++) {
			//产生1到35的随机数
			a[i] = (int)(1+Math.random()*35);
			m = a[i];
			if(i >= 1) {
    			for(j = 0;j < i;j++) {
					if(a[j] == m){
						i--;
						continue ;
					}
				}
			}
			if(a[i] < 10)
				System.out.println("0"+a[i]);
			else
				System.out.println(a[i]);
		}
	}
}
